package homework4;

public class Chapter06 {
    public static void main(String[] args) {
        int num=0;
        for (int i=2;i<=10000;i++){
            for (int j=2;j<=i;j++){
                if (i%j==0&&i!=j){
                    break;
                }else if (i%j==0&&i==j){
                    num++;
                    System.out.println(i);
                }
            }
        }
        System.out.println(num);
    }
}
